|
Part
Seven: Overview
In this section
you will begin setting up the resources.
|
7.1
|
Copy
the relevant map distribution files to the map folder.
|
|
7.2
|
Edit
the Resource.missphere
file. |
|
7.3
|
Add
Resources using Excel to the Resource.missphere
file. |
|
7.4
|
Edit
the Asteroid.dist
file. |
|
7.5
|
Finish
up the Resource.missphere
file and its
associated distribution files. |
|
7.6
|
Add
a final "Tail"
to the spiral. |
|
7.7
|
Part
Seven Summary. |
|
Quick Links Relevant
to this Chapter
|

7.0
Resources
The
Resource.missphere
file
contains every single resource element that we want to use
in the map including asteroids, dust clouds and particles.
When ships are placed in the ResourceSphere they go under
AI control, even when playing with no computer players.
There will only ever be more than one of these if it becomes
bigger than 64k. Derelicts, mines, crystals and other ships
and junk all go in here as well. Crystals we have already
spoke about, we will cover mines later when we add in the
derelicts, i.e. the station and its defenses.
So,
w e know exactly what is going on in the Resources
and Distribution Files,
we know that not only the resource clusters are here, but
also if we want AI controlled ships and other derelicts
or scenery then they all go in here too.

7.1
- Copy
the relevant map distribution files to the map folder.
In
your DSpiral2 folder delete all the *.dist files.
Now, go into the Tutorial Map Folder, you will find
three more distribution files called Asteroid.dist,
DustCloud.dist and, Tiny.dist copy these
into your DSpiral2 folder. Dont worry about the distribution
files at the moment, they are simple text files that have
the data pertaining to the range of sizes of each resource
type, and should we need it; the regeneration rates of these
resource types. We will deal with these later, but we add
them now so we can jump in and out of the game and see our
changes as we make them.

7.2
- Edit
the Resource.missphere
file.
Open
up the
Resource.missphere
file
now, we will ignore the 3 line header beginning with the
semicolon and deal with the rest.
7.2.1
- We are going to delete every line bar the three
header lines at the top (the Relic header lines, those three
that start with a semicolon. [ ; ]).
We
could if we wished keep One Resource line, and One
crystal line and delete every other resource lines bar the
first two lines. The reason we would want to keep these
lines is because it makes a handy template to build our
resources from. Copying and pasting away, like there's no tomorrow.
7.2.2
- Okay an average resource line looks like this;
;Resources
Asteroid,-185.9,10.3,-925.0,Cylinder,04medium.dist,20,3900.0,1980.0,90.0,180.0,0,?
which
reads:
Resources
resourcetype,
posx, posy, posz,
layout, distribution, numResources,
radius, length, roty, rotz,
properties, propertiesparam..
7.2.3
- So lets add some resources in here.
We
will work through this using Excel. There are a number of
ways to deal with resource addition, although I can't recommend
any way other than Excel. If you are thinking along the
lines of; "So, Why are we using Excel?", "I
don't have Excel how on earth am I going to learn anything?"
or even "What other ways can you edit?"
Then your in luck, I will explain further my choice and
reasons of by illustrating answering these questions thusly;
7.2.3.1
- Working by hand. i.e.; Pen,
Paper and Calculator.
Do
all the working by Hand. i.e. sit with a drawing of your
map and work out the length, angle and co-ordinates of each
line by calculator, abacus, fingers or whatever is certainly
a possibility. This is as you can imagine extremely long
and drawn out and massively boring. I don't recommend it
at all. Jump over to the Chapter Seven Notes Page where
I discuss how I would go about turning a spiral drawing
into a map and doing the entire thing with nothing more
than a Pen, Piece of paper and a calculator. Just
be sure to return back here and continue off where you left
off. Anyway, just because I loath the idea of all that math
doesn't mean I've completely neglected all you without Excel.
I will be sure to discuss how everything we do with excel
can be done by hand, usually I'm gloating, but it will help...
Also, every co-ordinate for every line that you will need
has been made available to you at no extra cost, I will
be sure and make sure everything you need is available if
you can't do it for yourself in excel. If
you are stuck with doing it by hand then it will save you
all that work. I'm nice that way. Anyway if you insist on
the pen/paper approach here are three documents that may
be of help to you.
| Working
Resources by Hand |
Chapter
Seven Notes:
Tutorial Notes, they are a bit vague on the actual
working, but a good starting place so you can see
why you need the trig and exactly what to do with
it. |
| Introduction
to Trigonometry |
Appendix
B: This
is an excellent place to start if you are interested
(?!) in learning how to use trigonometry. Covers all
the basics extremely well and is a good companion
to the more in-depth: |
| Trigonometry:
A Crash Review |
Appendix
B: A
more In-depth discussion on Trig, This file covers
pretty much every aspect of basic Trig in superb detail.
Easily understandable and well written. |
7.2.3.2
- Working with MissionMan.
The
problem here is, other than it crashes your system every
five minutes, and its impossible to use, MissionMan does
not lend itself to regular shapes. Rings and such are possible,
but they never really look any good. It can make good random
streams of asteroids (end to end cylinders), but then Excel
does it better and faster, again, not recommended.
7.2.3.3
- Working
with Excel
I
use Excel and I am going to continue this tutorial using
it. It really is massively simple, as you will see. Highly
Recommended. We will be using Excel throughout the remainder
of this tutorial. I strongly suggest you use Excel. And
here's how. Get hold of the HW:C SRD-XL Utility.
Try here for
a starting point if you don't have it. You have it? Great
then open it up now. If you don't/can't/won't use Excel
then don't worry , I will supply the co-ordinates you will
need to continue using this tutorial, just be sure to have
a quick glance at the section on Working
Resources by Hand so you know what's going on.
7.3
- Add
Resources using Excel to the Resource.missphere
file.
Right.
We have drawn out a concept sketch of our map, which you
will have seen in the introduction of this tutorial. What
you haven't seen so far is this:
fig One - Top Elevation
I have
drawn out the map on graph paper. The map consists of a
single spiralling strand of asteroids, here we see a top
elevation of the spiral. This spiral will be made up of
a long chain of straight cylinders, all lying end to end.
I have drawn some of those straight lines in, but just ignore
them. Its the spiral you are interested in.
One
last thing here: "How did I get the Z axis co-ordinates?"
Well, I will tell you dearest reader: I know I want the
spiral to drop from top to bottom, and I chose an arbitrary
amount of having it drop 128000 (128km) from very top to
very bottom. There are 8 half circles in the map, so each
half circle is going to drop 16000 (16km). There are eight
lines making up each half circle of the spiral, so each
line must drop 2000 (2km) from end to end. From this I can
get the Z axis values for each point.
To
save you the trouble of all this working out, I will supply
the co-ordinates you need later, but at this point of writing
I am at the same stage as you, and things may well change
as we go on. So read on. I will now show you how much easier
all this is when you use Excel or some other spreadsheet
utility.
7.3.1
- Working
with Excel: Using the HW:C Strands, Rings and Distances
Excel Utility. (The HW:C SRD-XL Utility)
We
are making a downward spiral, and the HW:C SRD-XL Utility
does not cover that per se, so we will jury rig the
answers we want, because everything we need is already there.
Now,
the Utility can do rings, so were set. We
could use the Strand Creator and using the graph
and simply read off the co-ordinates we want, like I have
been talking about so far, but we won't. You see, The strands
generator will generate a cylinder of asteroids between
the co-ordinates you list. The co-ordinates of a cylinder
is the exact cente of a cylinder right? And we know what
points we want the spiral to pass through right? The co-ordinates
we have. Well, the rings are generated around a single set
of coordinates, how handy, we can find the exact centre
of each line, as well as the angle of the line between the
start and end points of each half circle, and use them
to create a correctly tilted ring. How stunningly awesome.
That's why excel is so useful.
So,
in our map we know the starting and ending locations of
the first spiral half (the outermost & Uppermost end
of the Spiral), as shown in fig Four below, termed A and
B. We will recreate the line AB in the Strand Generator.

Fig Four - Top Elevation (Arc AB)
Line
AB will be tilting the same way we want our spiral to be
and it will have the co-ordinates of the exact centre of
the half circle (arc AB) So, we'll do this by using
Rings and editing out the halves we don't need. We
know that our spiral is actually drawn out as 8 half circles.
That's merely 8 rings, with half the rings deleted. You
see? Obvious...
This
way we can work faster - there is less for us to
do. Also, more importantly, tweaking is a lot easier and
quicker and hence less daunting. Another bonus to using
rings is that TAKER set his Ring maker up to make 24 sided
rings, 24 end to end cylinders in a circle. We will have
twelve cylinders making up the semi-circle, instead of 8.
The end result will be much better looking.
The map spirals downwards (as I keep saying, I know, I'm
sorry), and we know at what rate it does this - well at
least I do, but hey, I will tell you too, it will have dropped
16km (16000) every half circle of the spiral.
7.3.2
- Finding
the co-ordinates and angles of each ring.
So
lets start off using the first sheet, the Strands
Generator sheet. Here we will draw in each line to
get the exact centre of the ring (which is the same as the
exact centre of the line; Pos x, Pos y & Pos z) and
the angle we need to create a good looking spiral downwards,
(it will be the angle about the Y axis - Rot y
on the strands sheet) .
So,
while we are here in the Strands Generator Sheet, lets plug
in the co-ordinates for all the start/end points of the
half circles we require. I'll list them here, although you
could easily get them yourselves from Fig One.
7.3.3
- Input
the values shown below in the Strand Generator.
These
values I have read directly from the drawn out map above
using a scale of 1cm=10000 (10km). Here's how I named the
rest of the Points. So, we will be looking for data on:
Line AB, BC,CD,DE,EF,FG,GH and HO. This is pretty straight
forward right? Just remember that the direction of
the line is important.

Fig
Five - Top Elevation (Arcs BC & CD)
Spiral
Ring Co-ordinates
Use in this order and add these co-ordinates into the
Strands Generator sheet.
| U |
-100000,
0, 72000
|
| A |
80000, 0,
64000
|
| B |
-80000, 0,
48000
|
| C |
60000,
0,
32000
|
| D |
-60000, 0,
16000
|
| E |
40000,
0,
0
|
| F |
-40000, 0,
-16000
|
| G |
20000,
0,
-32000
|
| H |
-20000,
0,
-48000
|
| O |
0,
0, -64000
|
| T |
-20000,
0, -80000
|
7.3.4
- Whoah!!
Where the HELL did Points 'U' and 'T' Come
from!!!
Don't
worry about these, I have had a little look at the results
so far and based on starting positions and so on, have taken
the quick decision to add an extra half circle at the top
(U) and an extra half circle - a Tail at the
bottom (T). I got these co-ordinates by simple mental
arithmatic, extrapolating up from point A and down from
point O. Basic stuff.
7.3.5
- So
what have we got now?
Take
a look at the results churned out in the workings box next
to these inputed values. Looking at the results for line
UA first.
Line
UA Results from the Strand Generator:
| Cylinder |
1-2 |
| Pos
x |
-10000.0 |
| Pos
y |
0.0 |
| Pos
z |
72000.0 |
| Length |
180709.7 |
| Rot
Y |
185.1 |
| Rot
Z |
0.0 |
You
know all this but to summarise; Inputting in the co-ordinates
of U; (-100000,
0, 80000)
and the co-ordinates of A; (80000,
0, 64000)
will give you the angle that the halfcircle will have for
it to drop 16km from start to finish.
What
it's actually doing is generating the co-ordinates for a
cylinder (a straight line) stretching between these two
points. The results for this cylinder are actually ready
to be used, if you check out the ResourceSphere sheet you
will find the results are outputted here and you only need
to save this sheet as a *.csv file and then copy the *.csv
data directly into your ResourceSphere.missphere file and
thats that. We are just using the math thats gone on here
like we would a calculator...
Looking
at the results we got on the Strands Generator sheet;
Cylinder
This
is just telling us that it is lines 1 and 2 from the lines
you have added to the strand generator.
Pos
x, Pos y & pos z
The central co-ordinates required for a cylinder, (a straight
line) that will start and end at the co-ordinates you
have added.
Length
The
distance between the two Points is shown at 180709.7 .
We will use this number for our radius, or rather we will
use half this number as it actually gives us the
diameter of the circle we will have and we want the radius...
Rot
Y
The rotation about the Y axis (Rot Y) which the our up/down
angle we will require our ring to have (although we will
only use half the ring). Now typing in these numbers
gives us the angle we seek, namely 185.1° tilt. Because
180° is just a half-rotation and is a 2D object, this
would be the same as saying a 5.1° tilt. Right?
Rot
Z
The
Rotation about Z axis (Rot Z - which will be 0°,
although it will tell you its 180°, it doesn't matter
although you will know this, its really basic trig)
we will ignore this.
7.3.6
- Input
the values generated by the Strand Generator into the Rings
Sheet.
In
the Rings sheet, We will fill in the boxes
with the numbers we have just generated.
Radius-X
The
size of the ring we want, it's radius. From the
strands sheet this is half the length of the distance
between the two points (Length)
which
is; 80399
Tilt
X (deg)
From
the strands sheet this will be our Rotation about
the Y axis value (Rot Y), which reads 185.1, but
as 180°
is just be effectivly turning the ring upside down, the
actual angle we need is; -5.1
Shift
x,y and z
These
values will be the co-ordinates that designate the centre
of the ring (or the 'origin', or on our map 'Point O'
or even 'co-ordinates 0,0,0', heh). From the strands sheet
this will be the centre of the line, the actual
co-ordinates of the cylinder generated there, (Pos x,
Pos y & Pos z).
Pos
x is -10000, Pos y is 0 and Pos
z is; 72000
-
Repeat this For All 5 Ring Sheets,
using the co-ordinates/angles generated from the Strand
Generator sheet. We have 5 ring sheets at our disposal,
so set up the first 5 Rings.
Remember
though; the second line will be measured in the opposite
direction, it drops in the opposite direction, and so although
it says the angle is 185.7 you would not read
it as -5.7 but as 5.7, you can see
this easily on the line as the Rot z is 180°.
Reverse the ring tilt for alternate Rings (i.e. Lines UA,
BC,DE,FG and HO will have negative Tilt X (deg) values).
7.3.7
- Copy
the results generated by the Rings Generators into the Resource.missphere
file.
OK
once you have filled in the data required, jump over to
the Rings Resources sheet where you can see the co-ordinates
are all ready for you, and in an easier order to read than
on TAKER's Rings sheet. Now save this sheet as a comma delimited
file(csv) which can be read with any text file, and is happily
saved in exactly the format HW:C requires, with commas separating
the values. Save the sheet as Rings Resources.csv
in your DSpiral2 folder.
Now
open up this csv file using Textpad (or note pad
or indeed any other text editor, if you want things to be
difficult and fiddly for yourself). Copy the entire five
sets of Ring co-ordinates, directly into your Resource.missphere
file.
Save
the file and go and have a little shufty at the results
so far, in Cataclysm. You should have five rings on top
of one another, each successive ring dropping in the opposite
direction to the previous one. And looking not unlike this:

7.3.8
- Create the last few rings using a separately saved XL
Spreadsheet.
Save
your open XL Spreadsheet as Tutmap1.xls. We already
have all our data inputted so we will keep it handy and
not copy over it. Open up the original copy of the HW:C
SDR-XL again.
Copy/paste
the co-ordinates you inputted in the Strands Generator on
the Tutmap1.xls spreadsheet, into the newly opened, original
SRD-XL, Strands page.
Set
up the last 5 rings in the same way you did in 7.3.6, use
the results to make the rings from Lines FG, GH and HO).
Save this second Excel spreadsheet as Tutmap2.xls.
Now, in the same way you done it in 7.3.6, add those rings
into the map and take another look.
7.3.9
- Tweak the ring so it becomes a spiral.
We will tweak our ring from Excel, again this allows any
global changes we need to be made easier in the future.
Go into the Rings ResourceSphere sheet and lets delete
all the lines we don't need. Well, we won't actually delete
them because you never know, we may suddenly need them in
the future (Sod's law dictates we will). What we will do
is get the game to ignore specific lines by the usual way
of adding a semicolon in front of each line we don't want.
Now,
if you have been following me closely you should have the
same set up as me, I will summarize all 10 rings below in
case me and you differ somewhere, it should make the next
bit easier.
Tutmap1.XLS
|
Ring
Sheet
|
Spiral
Part
|
Radius-X
|
Tilt
X (deg)
|
Shift
X
|
Shift
Y
|
Shift
Z
|
Delete
Lines on csv sheet
|
|
1st
|
1
[UA]
|
90354.9
|
-5.1
|
-10000
|
0
|
72000
|
First
12 lines (All -X,-Y and +X, -Y areas)
|
|
2nd
|
2
[AB]
|
80399.0
|
5.7
|
0
|
0
|
56000
|
Last
12 lines (All -X,+Y and -X, +Y areas)
|
|
3rd
|
3
[BC]
|
70455.0
|
-6.5
|
-10000
|
0
|
40000
|
First
12 lines (All -X,-Y and +X, -Y areas)
|
|
4th
|
4
[CD]
|
60531.0
|
7.6
|
0
|
0
|
24000
|
Last
12 lines (All -X,+Y and -X, +Y areas)
|
|
5th
|
5
[DE]
|
50635.0
|
-9.1
|
-10000
|
0
|
8000
|
First
12 lines (All -X,-Y and +X, -Y areas)
|
Tutmap2.XLS
|
Ring
Sheet
|
Spiral
Part
|
Radius-X
|
Tilt
X (deg)
|
Shift
X
|
Shift
Y
|
Shift
Z
|
Delete
Quadrants
|
|
1st
|
6
[EF]
|
40792.0
|
11.3
|
0
|
0
|
-8000
|
Last
12 lines (All -X,+Y and -X, +Y areas)
|
|
2nd
|
7
[FG]
|
31048.4
|
-14.9
|
-10000
|
0
|
-24000
|
First
12 lines (All -X,-Y and +X, -Y areas)
|
|
3rd
|
8
[GH]
|
21540.7
|
21.8
|
0
|
0
|
-40000
|
Last
12 lines (All -X,+Y and -X, +Y areas)
|
|
4th
|
9
[HO]
|
12806.3
|
-38.7
|
-10000
|
0
|
-56000
|
First
12 lines (All -X,-Y and +X, -Y areas)
|
|
5th
|
10
[OT]
|
12806.3
|
-38.7
|
-10000
|
0
|
-72000
|
Last
12 lines (All -X,+Y and -X, +Y areas)
|
7.3.9.1
- Okay Blank out the lines by using the semi-colon
in front of the lines you don't want on your map, you want
rid of the lines as indicated in the 'Delete
Quadrants' box of the above tables.
7.3.9.2
- Next we want to point each resource line
at the Asteroid.dist distribution file, so delete
Tiny.dist and replace it with Asteroid.dist,
for every line.
7.3.9.3
- Deal
with the resourceNum and radius for each cylinder. We want
a seamless spiral very thick at the top and very thin but
not completely sparse at the bottom.
Using
the pos z value as an indicator of where I was on
the spiral, i found it easier to keep an eye exactly what
point of the spiral I was dealing with.
7.3.9.3.1
- Radius
By starting at a value of radius=400 at the very lowest
point of our spiral and ending with a radius of 6000 at
the uppermost part of the spiral I gradually incremented
as i rose up the spiral.
7.3.9.3.2
- numResources
Set
up the resources, starting at the very bottom at 3 and ending
at the uppermost part of the spiral at 60. Try to make an
even increment all the way up the spiral.
Where
the different rings meet, you will notice a change in the
length of each cylinder, what I do is; with a calculator
work out the average 'density' of asteroids against the
average 'density' of the next cylinder in line and try and
get a ratio similar.
i.e.
the lowest ring ends with a length of 3344, it joins to
the next part of the spiral with cylinders of length of
5623, 5623/3344=1.68, the first cylinder of length 5623
has resource density of 50, so 50/1.68=30, I therefore give
the last cylinder of length 3344 a resource density of 30
and work down from there. And so on. This helps make for
seamless joins between two differently lengthed cylinders.
I just plucked these numbers out the air to illustrate this,
but you get the idea..
Note:
I
saved each Rings Resources sheet from Tutmap1.xls as Rings
Resourcesphere1.csv and Tutmap2.xls Rings Resourcesphere2.csv.
They have been included in the HW:C Tutorial Map Files Folder,
so those of you without Excel, or if you have got hopelessly
lost somewhere before here, you can copy and past all the
co-odinates for our spiral direct from there.
7.3.9.4
- The
property value for this sphere is not set at anything, this
is cool as we don't want them to do anything, like regenerate.
We have the propertiesParam set at the default of ?, this
is fine, we will leave them be.
And
thats it. Save your results and copy them into the
resource.missphere file. Away into HW:C again. Your
map should look a little like this;

Take
a look at everything so far then Alt-Tab back to desktop.
Lets go on to discuss the distribution files in a bit
more depth.

7.4
- Edit
the Asteroid.dist
file.
This
file contains the information on the size and amounts of
each size of the resource you have in a cluster. They are
very simple files giving the relative sizes of asteroids/dustclouds
of the resources named in the Resourcesphere file. There
can be any amount of distribution files in the folder.
We
now know that the range of sizes of each resource type,
and the range of regeneration are found in the distribution
file that each resource line names. Lets give a slightly
higher emphasis to the ratio of asteroids found in the Asteroid.dist
file. Change the Asteroid.dist file lines to match this;
Asteroid0
5
1
Asteroid1
2
2
Asteroid2
3
2
Asteroid3
3
1
Asteroid4
1
0
The
second column of numbers is the regenation distribution
ratio values. As we have not switched on regeneration (property
value 2048), these are redundant here. If you wanted you
could quite happily delete them.
Lets
finish up the Resourcesphere by cleaning up and finishing
off the resources.
7.5
- Edit
the Resource.missphere
file and it's associated
distribition files.
OK,
after taking a look at the spiral I think I would like to
have huge asteroids at the top and teeny ones at the bottom.
Gravity is getting dense down there right? Also we will
add in our crystals down at the bottom as well.
In
the HW:C Tutorial map files folder you will have noted that
I also added in a folder called HWC Dist Files. These
came directly from the game itself, they can all be found
in a number of maps BD have produced, as well as all the
singleplayer maps if you'd care to look. They can be split
into three different groups, and from smallest to largest
those groups are;
Mixed
Asteroids
01bluerare; 02rare; 03mediumrare; 04medium; 05mediumwell;
06well; 07verywell and cata (has full range)
Single
Asteroids
type0; type1; type2; type3; type4 and even (has 1 of each
type)
Dustclouds
Dustcloud and dustcloudcentre (has 1 of each type)
They
are nothing special, really, just handy to have around.
handy for you as well as you don't need to go and create
them.
7.5.1
- Delete
every dist file in your DSpiral folder, then open the HWC
Tutorial Map Files/HWC Dist Files folder and copy all the
Mixed asteroid dist files except the cata.dist file
into your DSpiral2 folder. That's 01bluerare to 07verywell
on the list above.
7.5.2
- Now,
in your resourcesphere, delete every line hidden from the
game by a semicolon, if you haven't already. You should
be left with a huge long list of lines. 108 lines to be
precise. Save the file.
7.5.3
- Next open up Excel again and open up the
Resource.missphere file in Excel.
If
you are wondering how on earth to open up your resourcesphere
file in excel, well don't worry, its pretty simple, you
can see a note on exactly how to to it here.
7.5.4
- You
have a lot to do here now. I want you to change the distribution
files in each line. Starting with the top add 07verywell.dist,
after 10-15 lines change to 06well.dist and so on all the
way down to our last few entries which i want you to have
as 01bluerare.dist.
Once
you have finished, check the radius of each cylinder, this
is its thickness, do they match well where the rings join,
or could you afford to tweak them? You can save the file
as Resource.missphere (in .csv format) and then jump into
Cataclysm, take a look and jump back to excel and tweak
that way. just try and make it look as smooth as possible.
Once
you have finished save the file as a *.csv formatted file,
calling it Resource.missphere. And then close the file.
7.5.5
- Jump back to Textpad. I want you to now
open all the new distribution files you added. Change
Asteroid0 to 5 for every one of them, then
close them up again. The stock files we are using look a
little dense, so I want to thin it down a little without
reducing the total amount of asteroids present.
Take
a look at the results in Cataclysm. Not bad eh? I have included
the file as I have it at this stage as Resource2.missphere
in the HW:C Tutorial map files folder. If you need it it
is there, you can copy the entire contents directly into
your Resourcesphere.

Summary
Take
a look at the results in Cataclysm, a lot, lot better huh?
We are finished with the resources, I am happy, if you are
not then you know what to do, and how to do it.
Lets
move onto the more fun stuff that HW:C has to offer, namely
Mines,
Meteor Storms, Slipgates and Crystals.
[top]
[On
to Part Eight - Tweaking]
[Back
to Part Six]
[Main]
|